-
Notifications
You must be signed in to change notification settings - Fork 1.1k
PYTHON-2948 Add prose test for SRV polling with a custom service name #764
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
test/test_srv_polling.py
Outdated
sleep(2*common.MIN_SRV_RESCAN_INTERVAL) | ||
final_topology = set(client.topology_description.server_descriptions()) | ||
self.assertIn(response[0], final_topology) | ||
self.assertIn(response[1], final_topology) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can use assert_nodelist_change instead of:
sleep(2*common.MIN_SRV_RESCAN_INTERVAL)
final_topology = set(client.topology_description.server_descriptions())
self.assertIn(response[0], final_topology)
self.assertIn(response[1], final_topology)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah I could have have sworn I tried using assert_nodelist_change and it didn't work, but I just tried it again and it does work. Done.
test/test_srv_polling.py
Outdated
"mongodb+srv://test22.test.build.10gen.cc/?srvServiceName" | ||
"=customname") | ||
with SrvPollingKnobs( | ||
dns_resolver_nodelist_response=nodelist_callback): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This needs to be rebased to fix the dns_resolver_nodelist_response rename in PYTHON-2832
024c2d0
to
0a17e60
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM once the tests pass.
No description provided.